<template>
    <div>


        <button> @click="add">点击增加</button>
        <h3>>number:{{ number }}</h3>
        <h3>全局状态中的count:{{  $store.state.name }}</h3>
    </div>
  </template>

  <script>
  import { ref } from 'vue'
  import { useStore } from 'vuex'
  export default {
    name: 'Counter',
    props: {
    },
    setup() {
        const store = useStore();
        const state = store.state;
        const number = ref(0);
            number.value = number.value++;
    }
  }
  </script>

  <style scoped>
  </style>